package com.yue;

import com.yue.config.TestConfig;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;

public class Test {
    static AnnotationConfigApplicationContext context;
    public static void main(String[] args) {
        context = new AnnotationConfigApplicationContext(TestConfig.class);

        printBeans();
    }
    public static void printBeans(){
        String[] beanDefinitionNames = context.getBeanDefinitionNames();
        for(String beanName:beanDefinitionNames){
            System.out.println(beanName);
        }
    }
}
